<%@ page language="java" contentType="text/html; charset=utf-8"
    pageEncoding="utf-8"%>
    <%@ taglib uri="/struts-tags" prefix="s"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<script>
function timeCheck(){
	var time = document.getElementById("flight.scheduletime").value;
	var time1 = document.getElementById("flight.arrivalTime").value;
	var flightnumber = document.getElementById("flight.flightnumber").value;

	var patrn = /^(0?[1-9]|1[0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9]$/;
	if(flightnumber==""){
	    alert("航班号不能为空！请重新填写");
	    document.form1.action ="/asims/airline_manage/airline_manag_OuDe_edit.jsp";
		document.form1.submit();
	    }
	else if(!patrn.exec(time)||!patrn.exec(time1)){
		alert("时间格式填写错误！请重新填写");
		document.form1.action ="/asims/airline_manage/airline_manag_OuDe_edit.jsp";
		document.form1.submit();
	}

} 
</script>
<title>ASIMS</title>
<link href="/asims/CSS/style.css" rel="stylesheet" type="text/css" />
</head>

<body>
	<div id="wrap">
		<div id="header">
			<h1 id="sitename"><a href="#">ASIMS</a></h1>
			<div id="nav">
				<div id="titleblock">
					<div id="subject">机场静态信息管理系统</div>
					<div id="spirit"><a href="#"><%= session.getAttribute("username") %> 已登录</a> | <a href="queryUserForIndex.action" target="_parent">个人信息维护</a> | <a href="/asims/login/login.jsp" target="_parent">注销</a></div>
				 </div>
				<div id="topmenu">
					<ul>
						<li><a href="/asims/login/index.jsp">首页</a></li>
						<li><a href="/asims/rolemanage/user_manag.jsp">用户和角色管理</a></li>
						<li class="active"><a href="/asims/airline_manage/airline_manag_InAr.jsp">航班信息管理</a></li>
						<li><a href="/asims/facilities_manag/facilities_manag.jsp">机场设施管理</a></li>
						<li><a href="/asims/news/news_view_intr.jsp">新闻中心</a></li>
					</ul>		
				</div>
			</div>
			<div class="clear"></div>
			<div id="breadcrumb">网站路径：<a href="/asims/login/index.jsp">首页</a> &raquo; <a href="#"  class="active">航班信息管理</a></div>
		</div>
		
		<div id="content">
			<div id="right">
			   <div class="post">
					<h2><a href="">航班信息修改</a></h2>
						<form name="form1" action="updateFlightById.action" method="post"  enctype="multipart/form-data">
							<div class="contactform">
								<p class="first">
									<label for="scheduledtime">计划时间：</label>
									<s:textfield name="flight.scheduletime" id="flight.scheduletime"></s:textfield>例如：12:02:00
								</p>
								<p>
									<label for="flightnumber">航班号：</label>
									<s:textfield name="flight.flightnumber" id="flight.flightnumber"></s:textfield>
								</p>
								<p>
									<label for="boardinggate">登机门：</label>
									<s:textfield name="flight.board" ></s:textfield>
								</p>
								<p>
									<label for="startingstation">始发地：</label>
									<s:textfield name="flight.origin" ></s:textfield>
								</p>
								<p>
									<label for="destination">目的地：</label>
									<s:textfield name="flight.destination" ></s:textfield>
								</p>
								<p>	
									<label for="stop">经停地：</label>
									<s:textfield name="flight.stop" ></s:textfield>
								</p>
								<p>	
									<label for="arrivaltime">离港时间：</label>
									<s:textfield name="flight.arrivalTime" id="flight.arrivalTime"></s:textfield>例如：12:02:00
								</p>
								<p>	
									<label for="airline">航空公司：</label>
									<s:textfield name="flight.airline" ></s:textfield>
								</p>
								<div class="buttons">
									<div class="butarea2"></div>
									<button type="submit" name="add" onclick ="timeCheck()">
										<img src="/asims/images/import16.png" alt=""/> 
										保存
									</button>
									<button type="reset" name="cancel" onclick ="javascript:window.location.href='/asims/listOuDeFlight.action'">
						<img src="/asims/images/cancel16.png" alt=""/> 
							取消
						</button>
								</div>	
							</div>
						</form>
				</div>
			</div>
			
			
				
			<div id="sidebar">
				<div id="sidebartop"></div>
					<h2>航班信息管理</h2>
						<ul>
						  <li><a href="listInArFlight.action">国内到港</a></li>
						  <li><a href="listInDeFlight.action">国内离港</a></li>
						  <li><a href="listOuArFlight.action">国际到港</a></li>
						  <li class="active"><a href="listOuDeFlight.action">国际离港</a></li>
						</ul>
			</div>
			<div class="clear"></div>
			<div id="bottom">
				<p>Copyright &copy; 20100507</p>
				<p><a href="">隐私权</a> | <a href="">&copy;版权</a> | <a href="">法律声明</a> | <a href="">电子邮件：admin@163.com</a>
			</div>
			</div>
			
			<div id="footer">
			<div id="credits">
				ASIMS Power by IBM
			</div>
		</div>
	</div>

</body>
</html>
